<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

return new class extends Migration
{
    /**
     * Run the migrations.
     */
    public function up(): void
    {
        //
        Schema::table('site_oldmaterial_olddata', function (Blueprint $table) {
            $table->tinyInteger('is_del')->default(1)
                ->comment('是否删除 1正常 2删除');
        });
    }

    /**
     * Reverse the migrations.
     */
    public function down(): void
    {
        //
        Schema::drop('site_oldmaterial_olddata');
    }
    //alter table `zhuxiaobao`.`zxb_site_oldmaterial_olddata` add `is_del` tinyint not null default '1' comment '是否删除 1正常 2删除'
    //alter table `zhuxiaobao`.`zxb_site_basic_template_quality` add `is_default_value` tinyint not null default '1' comment '是否默认值 1否 2是'
    //alter table `zhuxiaobao`.`zxb_site_basic_template_tag` add `is_default_value` tinyint not null default '1' comment '是否默认值 1否 2是'

    //菜单权限
//    INSERT INTO zhuxiaobao.zxb_site_menu_list (pid, keyIndex, name, path, hidden, component, always_show, title, icon, no_cache, link, is_botton, is_default, props, rule_typestr, default_rule_typestr) VALUES (104, '', '删除', '', 0, '', 1, '', '', 0, 0, 1, 1, '', '9', '9,1,2,3,4,11,12');
//    INSERT INTO zhuxiaobao.zxb_site_menu_list (pid, keyIndex, name, path, hidden, component, always_show, title, icon, no_cache, link, is_botton, is_default, props, rule_typestr, default_rule_typestr) VALUES (104, '', '批量删除', '', 0, '', 1, '', '', 0, 0, 1, 1, '', '9', '9,1,2,3,4,11,12');
/*create table zxb_site_store_contract_list
(
    id                    int unsigned auto_increment
        primary key,
    address_area          varchar(128)        default '' null comment '地址',
    admin_user_id         int unsigned        default 0  not null comment '所属超管',
    business_mem_id       int unsigned        default 0  not null comment '业务员编号',
    cp_id                 int unsigned        default 0  not null,
    create_at             int unsigned        default 0  not null,
    soft_year_fee         int(11) unsigned               not null comment '合同费用(门店的年费字段)',
    is_valid              tinyint             default 1  null comment '是否生效',
    store_name            varchar(128)        default '' not null comment '门店名称',
    store_relation_id     int                            null comment '门店关联id',
    pay_at                int unsigned        default 0  not null comment '支付时间',
    pay_type              int unsigned        default 0  not null comment '支付方式',
    pay_type_name         varchar(32)         default '' not null comment '支付方式名称',
    contact_name          varchar(32)         default '' not null comment '联系人，负责人',
    contact_phone         varchar(32)         default '' null comment '联系方式',
    contract_at           int unsigned        default 0  not null comment '合同签订时间',
    contract_audit_status tinyint unsigned    default 1  not null comment '1待审核，2审核中，3审核成功，4审核失败',
    contract_end_at       int unsigned        default 0  not null comment '合同到期时间',
    contract_file_path    text                           not null comment '合同图片',
    contract_type         tinyint(1) unsigned default 1  not null comment '合同类型，1新户合同，2续费合同',
    customer_service_id   int(10)                        not null comment '客服编号',
    update_at             int unsigned        default 0  not null,
    fee_log_id            int unsigned        default 0  not null comment '续费logid',
    remark                varchar(500)        default '' not null comment '合同备注',
    is_del                tinyint(1) unsigned default 1  not null comment '是否删除，1正常，2已删除',
    del_at                int unsigned        default 0  not null comment '删除时间'
)
   comment '门店合同列表' charset = utf8mb4;
*/
};

